An Efficient Algorithm for Computing MHP Information for Concurrent Java Programs
نویسندگان
چکیده
Information about which statements in a concurrent program may happen in parallel (MHP) has a number of important applications. It can be used in program optimization, debugging, program understanding tools, improving the accuracy of data flow approaches, and detecting synchronization anomalies, such as data races. In this paper we propose a data flow algorithm for computing a conservative estimate of the MHP information for Java programs that has a worstcase time bound that is cubic in the size of the program. We present a preliminary experimental comparison between our algorithm and a reachability analysis algorithm that determines the ”ideal” static MHP information for concurrent Java programs. This initial experiment indicates that our data flow algorithm precisely computed the ideal MHP information in the vast majority of cases we examined. In the two out of 29 cases where the MHP algorithm turned out to be less than ideally precise, the number of spurious pairs was small compared to the total number of ideal MHP pairs.
منابع مشابه
An E cient Algorithm for Computing MHP Information for Concurrent Java Programs
Information about which statements in a concurrent program may happen in parallel MHP has a number of important applications It can be used in program optimization debugging program understanding tools improving the accuracy of data ow approaches e g and detecting synchronization anomalies such as data races For example in optimization if it is known that two threads of control will never attem...
متن کاملA Practical MHP Information Analysis for Concurrent Java Programs
In this paper we present an implementation of May Happen in Parallel analysis for Java that attempts to address some of the practical implementation concerns of the original work. We describe a design that incorporates techniques for aiding a feasible implementation and expanding the range of acceptable inputs. We provide experimental results showing the utility and impact of our approach and o...
متن کاملDetecting Concurrently Executed Paris of Statements Using Adapted MHP Algorithm
Information about which pairs of statements in a concurrent program can be executed concurrently is important for improving the accuracy of dataflow analysis, optimizing programs, and detecting errors. This paper presents a new method named Concurrent Control Flow Graph for representing concurrent Ada programs in a simple and precise way. Based on this method, we develop an Adapted MHP (May Hap...
متن کاملMay-Happen-in-Parallel Analysis with Returned Futures
May-Happen-in-Parallel (MHP) is a fundamental analysis to reason about concurrent programs. It infers the pairs of program points that may execute in parallel, or interleave their execution. This information is essential to prove, among other things, absence of data races, deadlock freeness, termination, and resource usage. This paper presents an MHP analysis for asynchronous programs that use ...
متن کاملComplexity Results for May-Happen-in-Parallel Analysis
For concurrent and parallel languages, may-happen-in-parallel (MHP) analysis is useful as a basis for tools such as data race detectors. While many approximate static MHP analyses exist, researchers have published only a few papers on decidability results for MHP analysis. We study MHP analysis for a model of X10, a parallel language with async-finish parallelism. For programs with procedures, ...
متن کامل